import { createMemoryHistory, createRouter, createWebHashHistory, createWebHistory, RouteRecordRaw } from "vue-router";

const routes: RouteRecordRaw[] = [
	{
		path: "/",
		component: import("./App.vue"),
	},
];

export function createDefaultRouter() {
	const router = createRouter({
		history: import.meta.env.SSR ? createMemoryHistory() : createWebHashHistory(import.meta.env.BASE_URL),
		// history: import.meta.env.SSR ? createMemoryHistory() : createWebHistory(import.meta.env.BASE_URL),
		routes,
	});
	return router;
}

export default routes;
